package chapter_17_command.classic;

/**
 * @author yaochenglong
 * @date 2017/10/20
 * 调用者invoker类
 */
public class Invoker {

    private Command command;

    //接收命令
    public void setCommand(Command command) {
        this.command = command;
    }

    //执行命令
    public void action(){
        command.execute();
    }
}
